home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 30
/
Aminet 30 (1999)(Schatztruhe)[!][Apr 1999].iso
/
Aminet
/
dev
/
lang
/
SmallEiffel.lha
/
SmallEiffel
/
bin_c
/
compile_to_jvm9.c
< prev
next >
Wrap
C/C++ Source or Header
|
1998-12-22
|
21KB
|
1,041 lines
/*
-- ANSI C code generated by :
-- SmallEiffel The GNU Eiffel Compiler -- Release (- 0.79) --
-- Copyright (C), 1994-98 - LORIA - UHP - CRIN - INRIA - FRANCE --
-- Dominique COLNET and Suzanne COLLIN - colnet@loria.fr --
-- http://www.loria.fr/SmallEiffel --
*/
#include "compile_to_jvm.h"
void r340with_capacity(T340* C,T2 a1,T2 a2){
/*[IF*/
if(((C)->_capacity/*4*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
}
/*FI]*/
C->_lower=a2;
C->_upper=(a2)-(1);
}
void r340add_last(T340* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if(((C)->_capacity/*4*/)<((r340count(C))+(1))){
/*[IF*/
if(((C)->_capacity/*4*/)==(0)){
C->_capacity=16;
C->_storage=calloc((C)->_capacity/*4*/,sizeof(T0*));
}
else{
_new_capacity=(2)*((C)->_capacity/*4*/);
C->_storage=r341realloc((C)->_storage/*0*/,(C)->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
}
/*FI]*/
}
/*FI]*/
C->_upper=((C)->_upper/*8*/)+(1);
/*[IRF3.6put*/{T340* C1=C;
T0* b1=a1;
T2 b2=(C)->_upper/*8*/;
((C1)->_storage/*0*/)[(b2)-((C1)->_lower/*12*/)]=(b1);
}/*]*/
}
T0* r340item(T340* C,T2 a1){
T0* R=NULL;
R=((C)->_storage/*0*/)[(a1)-((C)->_lower/*12*/)];
return R;
}
T6 r340valid_index(T340* C,T2 a1){
T6 R=0;
R=(((C)->_lower/*12*/)<=(a1))&&((a1)<=((C)->_upper/*8*/));
return R;
}
T0* r340first(T340* C){
T0* R=NULL;
R=r340item(C,(C)->_lower/*12*/);
return R;
}
T2 r340count(T340* C){
T2 R=0;
R=(((C)->_upper/*8*/)-((C)->_lower/*12*/))+(1);
return R;
}
/*No:ARRAY[RUN_CLASS].lower*/
T6 r340fast_has(T340* C,T0* a1){
T6 R=0;
R=r340valid_index(C,r340fast_index_of(C,a1));
return R;
}
T2 r340fast_index_of(T340* C,T0* a1){
T2 R=0;
R=((C)->_lower/*12*/)+(r341fast_index_of((C)->_storage/*0*/,a1,((C)->_upper/*8*/)-((C)->_lower/*12*/)));
return R;
}
/*No:ARRAY[RUN_CLASS].upper*/
void r340copy(T340* C,T0* a1){
T2 _needed_capacity=0;
C->_lower=(((T340*)a1))->_lower/*12*/;
C->_upper=(((T340*)a1))->_upper/*8*/;
_needed_capacity=(((C)->_upper/*8*/)-((C)->_lower/*12*/))+(1);
/*[IF*/
if(((C)->_capacity/*4*/)<(_needed_capacity)){
C->_capacity=_needed_capacity;
C->_storage=calloc((C)->_capacity/*4*/,sizeof(T0*));
}
/*FI]*/
/*[IF*/
if((_needed_capacity)>(0)){
r341copy_from((C)->_storage/*0*/,(((T340*)a1))->_storage/*0*/,(_needed_capacity)-(1));
}
/*FI]*/
}
T6 r340empty(T340* C){
T6 R=0;
R=(r340count(C))==(0);
return R;
}
/*No:ARRAY[RUN_CLASS].capacity*/
/*No:ARRAY[RUN_CLASS].put*/
/*No:ARRAY[RUN_CLASS].storage*/
T0* r108twin(T108* C){
T0* R=NULL;
R=malloc(sizeof(*C));
*((T108*)R)=M108;
r108copy(((T108*)R),((T0*)C));
return R;
}
/*No:ARRAY[ASSERTION].clear_all*/
void r108add_last(T108* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if(((C)->_capacity/*4*/)<((r108count(C))+(1))){
/*[IF*/
if(((C)->_capacity/*4*/)==(0)){
C->_capacity=16;
C->_storage=calloc((C)->_capacity/*4*/,sizeof(T0*));
}
else{
_new_capacity=(2)*((C)->_capacity/*4*/);
C->_storage=r111realloc((C)->_storage/*0*/,(C)->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
}
/*FI]*/
}
/*FI]*/
C->_upper=((C)->_upper/*8*/)+(1);
/*[IRF3.6put*/{T108* C1=C;
T0* b1=a1;
T2 b2=(C)->_upper/*8*/;
((C1)->_storage/*0*/)[(b2)-((C1)->_lower/*12*/)]=(b1);
}/*]*/
}
/*No:ARRAY[ASSERTION].set_all_with*/
T0* r108item(T108* C,T2 a1){
T0* R=NULL;
R=((C)->_storage/*0*/)[(a1)-((C)->_lower/*12*/)];
return R;
}
T6 r108valid_index(T108* C,T2 a1){
T6 R=0;
R=(((C)->_lower/*12*/)<=(a1))&&((a1)<=((C)->_upper/*8*/));
return R;
}
T2 r108count(T108* C){
T2 R=0;
R=(((C)->_upper/*8*/)-((C)->_lower/*12*/))+(1);
return R;
}
/*No:ARRAY[ASSERTION].lower*/
T6 r108fast_has(T108* C,T0* a1){
T6 R=0;
R=r108valid_index(C,r108fast_index_of(C,a1));
return R;
}
void r108make(T108* C,T2 a1,T2 a2){
T2 _needed=0;
C->_lower=a1;
C->_upper=a2;
_needed=((a2)-(a1))+(1);
/*[IF*/
if((_needed)>(0)){
/*[IF*/
if(((C)->_capacity/*4*/)<(_needed)){
C->_storage=calloc(_needed,sizeof(T0*));
C->_capacity=_needed;
}
else{
/*[IRF3.6clear_all*/{T108* C1=C;
T0* __value=NULL;
/*[IRF3.6set_all_with*/{T108* C2=C1;
T0* c1=__value;
r111set_all_with((C2)->_storage/*0*/,c1,((C2)->_upper/*8*/)-((C2)->_lower/*12*/));
}/*]*/
}/*]*/
}
/*FI]*/
}
/*FI]*/
}
T2 r108fast_index_of(T108* C,T0* a1){
T2 R=0;
R=((C)->_lower/*12*/)+(r111fast_index_of((C)->_storage/*0*/,a1,((C)->_upper/*8*/)-((C)->_lower/*12*/)));
return R;
}
/*No:ARRAY[ASSERTION].upper*/
void r108clear(T108* C){
C->_upper=((C)->_lower/*12*/)-(1);
}
void r108copy(T108* C,T0* a1){
T2 _needed_capacity=0;
C->_lower=(((T108*)a1))->_lower/*12*/;
C->_upper=(((T108*)a1))->_upper/*8*/;
_needed_capacity=(((C)->_upper/*8*/)-((C)->_lower/*12*/))+(1);
/*[IF*/
if(((C)->_capacity/*4*/)<(_needed_capacity)){
C->_capacity=_needed_capacity;
C->_storage=calloc((C)->_capacity/*4*/,sizeof(T0*));
}
/*FI]*/
/*[IF*/
if((_needed_capacity)>(0)){
r111copy_from((C)->_storage/*0*/,(((T108*)a1))->_storage/*0*/,(_needed_capacity)-(1));
}
/*FI]*/
}
T6 r108empty(T108* C){
T6 R=0;
R=(r108count(C))==(0);
return R;
}
/*No:ARRAY[ASSERTION].capacity*/
/*No:ARRAY[ASSERTION].put*/
/*No:ARRAY[ASSERTION].storage*/
T0* r242twin(T242* C){
T0* R=NULL;
R=malloc(sizeof(*C));
*((T242*)R)=M242;
r242copy(((T242*)R),((T0*)C));
return R;
}
void r242add_last(T242* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if(((C)->_capacity/*4*/)<((r242count(C))+(1))){
/*[IF*/
if(((C)->_capacity/*4*/)==(0)){
C->_capacity=16;
C->_storage=calloc((C)->_capacity/*4*/,sizeof(T0*));
}
else{
_new_capacity=(2)*((C)->_capacity/*4*/);
C->_storage=r243realloc((C)->_storage/*0*/,(C)->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
}
/*FI]*/
}
/*FI]*/
C->_upper=((C)->_upper/*8*/)+(1);
/*[IRF3.6put*/{T242* C1=C;
T0* b1=a1;
T2 b2=(C)->_upper/*8*/;
((C1)->_storage/*0*/)[(b2)-((C1)->_lower/*12*/)]=(b1);
}/*]*/
}
T0* r242item(T242* C,T2 a1){
T0* R=NULL;
R=((C)->_storage/*0*/)[(a1)-((C)->_lower/*12*/)];
return R;
}
T2 r242count(T242* C){
T2 R=0;
R=(((C)->_upper/*8*/)-((C)->_lower/*12*/))+(1);
return R;
}
/*No:ARRAY[WHEN_ITEM].lower*/
/*No:ARRAY[WHEN_ITEM].upper*/
void r242copy(T242* C,T0* a1){
T2 _needed_capacity=0;
C->_lower=(((T242*)a1))->_lower/*12*/;
C->_upper=(((T242*)a1))->_upper/*8*/;
_needed_capacity=(((C)->_upper/*8*/)-((C)->_lower/*12*/))+(1);
/*[IF*/
if(((C)->_capacity/*4*/)<(_needed_capacity)){
C->_capacity=_needed_capacity;
C->_storage=calloc((C)->_capacity/*4*/,sizeof(T0*));
}
/*FI]*/
/*[IF*/
if((_needed_capacity)>(0)){
r243copy_from((C)->_storage/*0*/,(((T242*)a1))->_storage/*0*/,(_needed_capacity)-(1));
}
/*FI]*/
}
/*No:ARRAY[WHEN_ITEM].capacity*/
/*No:ARRAY[WHEN_ITEM].put*/
/*No:ARRAY[WHEN_ITEM].storage*/
/*No:FIXED_ARRAY[DICTIONARY[RUN_FEATURE,STRING]].clear_all*/
/*No:FIXED_ARRAY[DICTIONARY[RUN_FEATURE,STRING]].item*/
/*No:FIXED_ARRAY[DICTIONARY[RUN_FEATURE,STRING]].set_all_with*/
/*No:FIXED_ARRAY[DICTIONARY[RUN_FEATURE,STRING]].count*/
void r338resize(T338* C,T2 a1){
T0* _elt_default=NULL;
T2 _i=0;
T2 _new_capacity=0;
/*[IF*/
if((a1)<=(/*(IRF4.6count*/((C)->_upper/*8*/)+(1)/*)*/)){
C->_upper=(a1)-(1);
}
else{
_new_capacity=a1;
/*[IF*/
if(((C)->_capacity/*4*/)<(_new_capacity)){
/*[IF*/
if(((C)->_capacity/*4*/)==(0)){
C->_storage=calloc(_new_capacity,sizeof(T0*));
}
else{
C->_storage=r339realloc((C)->_storage/*0*/,(C)->_capacity/*4*/,_new_capacity);
}
/*FI]*/
C->_capacity=_new_capacity;
}
/*FI]*/
_new_capacity=(C)->_upper/*8*/;
C->_upper=(a1)-(1);
_i=(C)->_upper/*8*/;
while (!((_i)==(_new_capacity))) {
/*[IRF3.5put*/((C)->_storage/*0*/)[_i]=(_elt_default);
/*]*/
_i=(_i)-(1);
}
}
/*FI]*/
}
void r338make(T338* C,T2 a1){
/*[IF*/
if((a1)==(0)){
C->_upper=-(1);
}
else if(((C)->_capacity/*4*/)==(0)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else if(((C)->_capacity/*4*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else{
C->_upper=(a1)-(1);
/*[IRF3.6clear_all*/{T338* C1=C;
T0* __value=NULL;
/*[IRF3.6set_all_with*/{T338* C2=C1;
T0* c1=__value;
r339set_all_with((C2)->_storage/*0*/,c1,(C2)->_upper/*8*/);
}/*]*/
}/*]*/
}
/*FI]*/
}
/*No:FIXED_ARRAY[DICTIONARY[RUN_FEATURE,STRING]].upper*/
/*No:FIXED_ARRAY[DICTIONARY[RUN_FEATURE,STRING]].capacity*/
/*No:FIXED_ARRAY[DICTIONARY[RUN_FEATURE,STRING]].put*/
/*No:FIXED_ARRAY[DICTIONARY[RUN_FEATURE,STRING]].storage*/
void r361with_capacity(T361* C,T2 a1){
/*[IF*/
if(((C)->_capacity/*8*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
}
/*FI]*/
C->_upper=-(1);
}
void r361clear_all(T361* C){
T0* _value=NULL;
/*[IRF3.6set_all_with*/{T361* C1=C;
T0* b1=_value;
r266set_all_with((C1)->_storage/*4*/,b1,(C1)->_upper/*12*/);
}/*]*/
}
void r361add_last(T361* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if((((C)->_upper/*12*/)+(1))<=(((C)->_capacity/*8*/)-(1))){
C->_upper=((C)->_upper/*12*/)+(1);
}
else if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(2,sizeof(T0*));
C->_capacity=2;
C->_upper=0;
}
else{
_new_capacity=(2)*((C)->_capacity/*8*/);
C->_storage=r266realloc((C)->_storage/*4*/,(C)->_capacity/*8*/,_new_capacity);
C->_capacity=_new_capacity;
C->_upper=((C)->_upper/*12*/)+(1);
}
/*FI]*/
/*[IRF3.6put*/{T361* C1=C;
T0* b1=a1;
T2 b2=(C)->_upper/*12*/;
((C1)->_storage/*4*/)[b2]=(b1);
}/*]*/
}
/*No:FIXED_ARRAY[TYPE].set_all_with*/
T0* r361item(T361* C,T2 a1){
T0* R=NULL;
R=((C)->_storage/*4*/)[a1];
return R;
}
T2 r361count(T361* C){
T2 R=0;
R=((C)->_upper/*12*/)+(1);
return R;
}
void r361resize(T361* C,T2 a1){
T0* _elt_default=NULL;
T2 _i=0;
T2 _new_capacity=0;
/*[IF*/
if((a1)<=(r361count(C))){
C->_upper=(a1)-(1);
}
else{
_new_capacity=a1;
/*[IF*/
if(((C)->_capacity/*8*/)<(_new_capacity)){
/*[IF*/
if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(_new_capacity,sizeof(T0*));
}
else{
C->_storage=r266realloc((C)->_storage/*4*/,(C)->_capacity/*8*/,_new_capacity);
}
/*FI]*/
C->_capacity=_new_capacity;
}
/*FI]*/
_new_capacity=(C)->_upper/*12*/;
C->_upper=(a1)-(1);
_i=(C)->_upper/*12*/;
while (!((_i)==(_new_capacity))) {
/*[IRF3.6put*/{T361* C1=C;
T0* b1=_elt_default;
T2 b2=_i;
((C1)->_storage/*4*/)[b2]=(b1);
}/*]*/
_i=(_i)-(1);
}
}
/*FI]*/
}
void r361make(T361* C,T2 a1){
/*[IF*/
if((a1)==(0)){
C->_upper=-(1);
}
else if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else if(((C)->_capacity/*8*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else{
C->_upper=(a1)-(1);
r361clear_all(C);
}
/*FI]*/
}
/*No:FIXED_ARRAY[TYPE].upper*/
/*No:FIXED_ARRAY[TYPE].capacity*/
/*No:FIXED_ARRAY[TYPE].put*/
/*No:FIXED_ARRAY[TYPE].storage*/
void r377with_capacity(T377* C,T2 a1){
/*[IF*/
if(((C)->_capacity/*8*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
}
/*FI]*/
C->_upper=-(1);
}
T0* r377twin(T377* C){
T0* R=NULL;
R=malloc(sizeof(*C));
*((T377*)R)=M377;
r377copy(((T377*)R),((T0*)C));
return R;
}
/*No:FIXED_ARRAY[ADDRESS_OF].clear_all*/
void r377add_last(T377* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if((((C)->_upper/*12*/)+(1))<=(((C)->_capacity/*8*/)-(1))){
C->_upper=((C)->_upper/*12*/)+(1);
}
else if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(2,sizeof(T0*));
C->_capacity=2;
C->_upper=0;
}
else{
_new_capacity=(2)*((C)->_capacity/*8*/);
C->_storage=r378realloc((C)->_storage/*4*/,(C)->_capacity/*8*/,_new_capacity);
C->_capacity=_new_capacity;
C->_upper=((C)->_upper/*12*/)+(1);
}
/*FI]*/
/*[IRF3.5put*/((C)->_storage/*4*/)[(C)->_upper/*12*/]=(a1);
/*]*/
}
/*No:FIXED_ARRAY[ADDRESS_OF].item*/
/*No:FIXED_ARRAY[ADDRESS_OF].set_all_with*/
/*No:FIXED_ARRAY[ADDRESS_OF].count*/
void r377resize(T377* C,T2 a1){
T0* _elt_default=NULL;
T2 _i=0;
T2 _new_capacity=0;
/*[IF*/
if((a1)<=(/*(IRF4.6count*/((C)->_upper/*12*/)+(1)/*)*/)){
C->_upper=(a1)-(1);
}
else{
_new_capacity=a1;
/*[IF*/
if(((C)->_capacity/*8*/)<(_new_capacity)){
/*[IF*/
if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(_new_capacity,sizeof(T0*));
}
else{
C->_storage=r378realloc((C)->_storage/*4*/,(C)->_capacity/*8*/,_new_capacity);
}
/*FI]*/
C->_capacity=_new_capacity;
}
/*FI]*/
_new_capacity=(C)->_upper/*12*/;
C->_upper=(a1)-(1);
_i=(C)->_upper/*12*/;
while (!((_i)==(_new_capacity))) {
/*[IRF3.5put*/((C)->_storage/*4*/)[_i]=(_elt_default);
/*]*/
_i=(_i)-(1);
}
}
/*FI]*/
}
void r377make(T377* C,T2 a1){
/*[IF*/
if((a1)==(0)){
C->_upper=-(1);
}
else if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else if(((C)->_capacity/*8*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else{
C->_upper=(a1)-(1);
/*[IRF3.6clear_all*/{T377* C1=C;
T0* __value=NULL;
/*[IRF3.6set_all_with*/{T377* C2=C1;
T0* c1=__value;
r378set_all_with((C2)->_storage/*4*/,c1,(C2)->_upper/*12*/);
}/*]*/
}/*]*/
}
/*FI]*/
}
/*No:FIXED_ARRAY[ADDRESS_OF].upper*/
void r377copy(T377* C,T0* a1){
T2 _new_capacity=0;
T2 _other_upper=0;
_other_upper=(((T377*)a1))->_upper/*12*/;
/*[IF*/
if((_other_upper)>=(0)){
_new_capacity=(_other_upper)+(1);
/*[IF*/
if(((C)->_capacity/*8*/)<(_new_capacity)){
C->_capacity=_new_capacity;
C->_storage=calloc(_new_capacity,sizeof(T0*));
}
else if(((C)->_capacity/*8*/)>(0)){
r378clear_all((C)->_storage/*4*/,((C)->_capacity/*8*/)-(1));
}
/*FI]*/
r378copy_from((C)->_storage/*4*/,(((T377*)a1))->_storage/*4*/,_other_upper);
}
else if(((C)->_capacity/*8*/)>(0)){
r378clear_all((C)->_storage/*4*/,((C)->_capacity/*8*/)-(1));
}
/*FI]*/
C->_upper=_other_upper;
}
/*No:FIXED_ARRAY[ADDRESS_OF].capacity*/
/*No:FIXED_ARRAY[ADDRESS_OF].put*/
/*No:FIXED_ARRAY[ADDRESS_OF].storage*/
void r66with_capacity(T66* C,T2 a1){
/*[IF*/
if(((C)->_capacity/*4*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
}
/*FI]*/
C->_upper=-(1);
}
/*No:FIXED_ARRAY[BASE_CLASS].clear_all*/
void r66add_last(T66* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if((((C)->_upper/*8*/)+(1))<=(((C)->_capacity/*4*/)-(1))){
C->_upper=((C)->_upper/*8*/)+(1);
}
else if(((C)->_capacity/*4*/)==(0)){
C->_storage=calloc(2,sizeof(T0*));
C->_capacity=2;
C->_upper=0;
}
else{
_new_capacity=(2)*((C)->_capacity/*4*/);
C->_storage=r67realloc((C)->_storage/*0*/,(C)->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
C->_upper=((C)->_upper/*8*/)+(1);
}
/*FI]*/
/*[IRF3.5put*/((C)->_storage/*0*/)[(C)->_upper/*8*/]=(a1);
/*]*/
}
/*No:FIXED_ARRAY[BASE_CLASS].item*/
/*No:FIXED_ARRAY[BASE_CLASS].set_all_with*/
T6 r66valid_index(T66* C,T2 a1){
T6 R=0;
R=((0)<=(a1))&&((a1)<=((C)->_upper/*8*/));
return R;
}
/*No:FIXED_ARRAY[BASE_CLASS].first*/
/*No:FIXED_ARRAY[BASE_CLASS].count*/
/*No:FIXED_ARRAY[BASE_CLASS].lower*/
void r66resize(T66* C,T2 a1){
T0* _elt_default=NULL;
T2 _i=0;
T2 _new_capacity=0;
/*[IF*/
if((a1)<=(/*(IRF4.6count*/((C)->_upper/*8*/)+(1)/*)*/)){
C->_upper=(a1)-(1);
}
else{
_new_capacity=a1;
/*[IF*/
if(((C)->_capacity/*4*/)<(_new_capacity)){
/*[IF*/
if(((C)->_capacity/*4*/)==(0)){
C->_storage=calloc(_new_capacity,sizeof(T0*));
}
else{
C->_storage=r67realloc((C)->_storage/*0*/,(C)->_capacity/*4*/,_new_capacity);
}
/*FI]*/
C->_capacity=_new_capacity;
}
/*FI]*/
_new_capacity=(C)->_upper/*8*/;
C->_upper=(a1)-(1);
_i=(C)->_upper/*8*/;
while (!((_i)==(_new_capacity))) {
/*[IRF3.5put*/((C)->_storage/*0*/)[_i]=(_elt_default);
/*]*/
_i=(_i)-(1);
}
}
/*FI]*/
}
T6 r66fast_has(T66* C,T0* a1){
T6 R=0;
R=r66valid_index(C,r66fast_index_of(C,a1));
return R;
}
void r66make(T66* C,T2 a1){
/*[IF*/
if((a1)==(0)){
C->_upper=-(1);
}
else if(((C)->_capacity/*4*/)==(0)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else if(((C)->_capacity/*4*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else{
C->_upper=(a1)-(1);
/*[IRF3.6clear_all*/{T66* C1=C;
T0* __value=NULL;
/*[IRF3.6set_all_with*/{T66* C2=C1;
T0* c1=__value;
r67set_all_with((C2)->_storage/*0*/,c1,(C2)->_upper/*8*/);
}/*]*/
}/*]*/
}
/*FI]*/
}
T2 r66fast_index_of(T66* C,T0* a1){
T2 R=0;
R=r67fast_index_of((C)->_storage/*0*/,a1,(C)->_upper/*8*/);
return R;
}
/*No:FIXED_ARRAY[BASE_CLASS].upper*/
/*No:FIXED_ARRAY[BASE_CLASS].clear*/
/*No:FIXED_ARRAY[BASE_CLASS].capacity*/
/*No:FIXED_ARRAY[BASE_CLASS].put*/
/*No:FIXED_ARRAY[BASE_CLASS].storage*/
void r154with_capacity(T154* C,T2 a1){
/*[IF*/
if(((C)->_capacity/*8*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
}
/*FI]*/
C->_upper=-(1);
}
T0* r154twin(T154* C){
T0* R=NULL;
R=malloc(sizeof(*C));
*((T154*)R)=M154;
r154copy(((T154*)R),((T0*)C));
return R;
}
void r154clear_all(T154* C){
T0* _value=NULL;
/*[IRF3.6set_all_with*/{T154* C1=C;
T0* b1=_value;
r115set_all_with((C1)->_storage/*4*/,b1,(C1)->_upper/*12*/);
}/*]*/
}
void r154add_last(T154* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if((((C)->_upper/*12*/)+(1))<=(((C)->_capacity/*8*/)-(1))){
C->_upper=((C)->_upper/*12*/)+(1);
}
else if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(2,sizeof(T0*));
C->_capacity=2;
C->_upper=0;
}
else{
_new_capacity=(2)*((C)->_capacity/*8*/);
C->_storage=r115realloc((C)->_storage/*4*/,(C)->_capacity/*8*/,_new_capacity);
C->_capacity=_new_capacity;
C->_upper=((C)->_upper/*12*/)+(1);
}
/*FI]*/
/*[IRF3.6put*/{T154* C1=C;
T0* b1=a1;
T2 b2=(C)->_upper/*12*/;
((C1)->_storage/*4*/)[b2]=(b1);
}/*]*/
}
T0* r154item(T154* C,T2 a1){
T0* R=NULL;
R=((C)->_storage/*4*/)[a1];
return R;
}
/*No:FIXED_ARRAY[EXPRESSION].set_all_with*/
T2 r154count(T154* C){
T2 R=0;
R=((C)->_upper/*12*/)+(1);
return R;
}
void r154resize(T154* C,T2 a1){
T0* _elt_default=NULL;
T2 _i=0;
T2 _new_capacity=0;
/*[IF*/
if((a1)<=(r154count(C))){
C->_upper=(a1)-(1);
}
else{
_new_capacity=a1;
/*[IF*/
if(((C)->_capacity/*8*/)<(_new_capacity)){
/*[IF*/
if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(_new_capacity,sizeof(T0*));
}
else{
C->_storage=r115realloc((C)->_storage/*4*/,(C)->_capacity/*8*/,_new_capacity);
}
/*FI]*/
C->_capacity=_new_capacity;
}
/*FI]*/
_new_capacity=(C)->_upper/*12*/;
C->_upper=(a1)-(1);
_i=(C)->_upper/*12*/;
while (!((_i)==(_new_capacity))) {
/*[IRF3.6put*/{T154* C1=C;
T0* b1=_elt_default;
T2 b2=_i;
((C1)->_storage/*4*/)[b2]=(b1);
}/*]*/
_i=(_i)-(1);
}
}
/*FI]*/
}
void r154make(T154* C,T2 a1){
/*[IF*/
if((a1)==(0)){
C->_upper=-(1);
}
else if(((C)->_capacity/*8*/)==(0)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else if(((C)->_capacity/*8*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else{
C->_upper=(a1)-(1);
r154clear_all(C);
}
/*FI]*/
}
/*No:FIXED_ARRAY[EXPRESSION].upper*/
void r154copy(T154* C,T0* a1){
T2 _new_capacity=0;
T2 _other_upper=0;
_other_upper=/*X154upper*/((T2)(((T154*)a1))->_upper/*12*/);
/*[IF*/
if((_other_upper)>=(0)){
_new_capacity=(_other_upper)+(1);
/*[IF*/
if(((C)->_capacity/*8*/)<(_new_capacity)){
C->_capacity=_new_capacity;
C->_storage=calloc(_new_capacity,sizeof(T0*));
}
else if(((C)->_capacity/*8*/)>(0)){
r115clear_all((C)->_storage/*4*/,((C)->_capacity/*8*/)-(1));
}
/*FI]*/
r115copy_from((C)->_storage/*4*/,/*X154storage*/((T115)(((T154*)a1))->_storage/*4*/),_other_upper);
}
else if(((C)->_capacity/*8*/)>(0)){
r115clear_all((C)->_storage/*4*/,((C)->_capacity/*8*/)-(1));
}
/*FI]*/
C->_upper=_other_upper;
}
/*No:FIXED_ARRAY[EXPRESSION].capacity*/
/*No:FIXED_ARRAY[EXPRESSION].storage*/
/*No:FIXED_ARRAY[EXPRESSION].put*/
void r200with_capacity(T200* C,T2 a1){
/*[IF*/
if(((C)->_capacity/*4*/)<(a1)){
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
}
/*FI]*/
C->_upper=-(1);
}
void r200add_last(T200* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if((((C)->_upper/*8*/)+(1))<=(((C)->_capacity/*4*/)-(1))){
C->_upper=((C)->_upper/*8*/)+(1);
}
else if(((C)->_capacity/*4*/)==(0)){
C->_storage=calloc(2,sizeof(T0*));
C->_capacity=2;
C->_upper=0;
}
else{
_new_capacity=(2)*((C)->_capacity/*4*/);
C->_storage=r201realloc((C)->_storage/*0*/,(C)->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
C->_upper=((C)->_upper/*8*/)+(1);
}
/*FI]*/
/*[IRF3.5put*/((C)->_storage/*0*/)[(C)->_upper/*8*/]=(a1);
/*]*/
}
/*No:FIXED_ARRAY[CLASS_NAME].item*/
/*No:FIXED_ARRAY[CLASS_NAME].upper*/
/*No:FIXED_ARRAY[CLASS_NAME].capacity*/
/*No:FIXED_ARRAY[CLASS_NAME].storage*/
/*No:FIXED_ARRAY[CLASS_NAME].put*/
void r327add_last(T327* C,T0* a1){
T2 _new_capacity=0;
/*[IF*/
if(((C)->_capacity/*4*/)<((r327count(C))+(1))){
/*[IF*/
if(((C)->_capacity/*4*/)==(0)){
C->_capacity=16;
C->_storage=calloc((C)->_capacity/*4*/,sizeof(T0*));
}
else{
_new_capacity=(2)*((C)->_capacity/*4*/);
C->_storage=r328realloc((C)->_storage/*0*/,(C)->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
}
/*FI]*/
}
/*FI]*/
C->_upper=((C)->_upper/*8*/)+(1);
/*[IRF3.6put*/{T327* C1=C;
T0* b1=a1;
T2 b2=(C)->_upper/*8*/;
((C1)->_storage/*0*/)[(b2)-((C1)->_lower/*12*/)]=(b1);
}/*]*/
}
T2 r327count(T327* C){
T2 R=0;
R=(((C)->_upper/*8*/)-((C)->_lower/*12*/))+(1);
return R;
}
/*No:ARRAY[INDEX_CLAUSE].lower*/
/*No:ARRAY[INDEX_CLAUSE].upper*/
/*No:ARRAY[INDEX_CLAUSE].capacity*/
/*No:ARRAY[INDEX_CLAUSE].put*/
/*No:ARRAY[INDEX_CLAUSE].storage*/